CREATE TABLE [dbo].[TTBANC_FINA]
(
[CO_BANC] [dbo].[TD_VC_003] NOT NULL,
[DE_NOMB_BANC] [dbo].[TD_VC_050] NOT NULL,
[DE_NOMB_CORT] [dbo].[TD_VC_030] NOT NULL,
[CO_BANC_PLAN] [dbo].[TD_VC_003] NULL,
[ST_BANC_EMPR] [dbo].[TD_VC_001_SINO] NULL,
[CO_PAIS] [dbo].[TD_VC_003] NULL,
[CO_BANC_SUNA] [dbo].[TD_VC_002] NULL,
[CO_USUA_CREA] [dbo].[TD_VC_008_USUA] NULL CONSTRAINT [DF__TTBANC_FI__CO_US__24285DB4] DEFAULT (substring(suser_sname(),(1),(8))),
[FE_USUA_CREA] [dbo].[TD_DT_001_SIST] NULL CONSTRAINT [DF__TTBANC_FI__FE_US__251C81ED] DEFAULT (getdate()),
[CO_USUA_MODI] [dbo].[TD_VC_008_USUA] NULL CONSTRAINT [DF__TTBANC_FI__CO_US__2610A626] DEFAULT (substring(suser_sname(),(1),(8))),
[FE_USUA_MODI] [dbo].[TD_DT_001_SIST] NULL CONSTRAINT [DF__TTBANC_FI__FE_US__2704CA5F] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TTBANC_FINA] WITH NOCHECK ADD CONSTRAINT [CK__TTBANC_FI__ST_BA__2334397B] CHECK NOT FOR REPLICATION (([ST_BANC_EMPR]='N' OR [ST_BANC_EMPR]='S'))
GO
ALTER TABLE [dbo].[TTBANC_FINA] ADD CONSTRAINT [PK__TTBANC_F__A244ACAC3F3159AB] PRIMARY KEY CLUSTERED  ([CO_BANC]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TTBANC_FINA] ADD CONSTRAINT [FK__TTBANC_FI__CO_PA__4E3E9311] FOREIGN KEY ([CO_PAIS]) REFERENCES [dbo].[TTPAIS] ([CO_PAIS])
GO
GRANT SELECT ON  [dbo].[TTBANC_FINA] TO [public]
GRANT INSERT ON  [dbo].[TTBANC_FINA] TO [public]
GRANT DELETE ON  [dbo].[TTBANC_FINA] TO [public]
GRANT UPDATE ON  [dbo].[TTBANC_FINA] TO [public]
GO
